home *** CD-ROM | disk | FTP | other *** search
/ SGI Hot Mix 17 / Hot Mix 17.iso / HM17_SGI / html / vendors / cocreate / fixem < prev    next >
Text File  |  1997-06-17  |  295b  |  15 lines

  1. #!/bin/perl
  2.  
  3. $file = shift(@ARGV);
  4. `cp $file file.bak`;
  5. open(OLDFILE, "file.bak") || die "Couldn't open file.bak\n";
  6. open(NEWFILE, "> $file") || die "Couldn't open $file\n";
  7. while(<OLDFILE>){
  8.     if (/(.*)_top(.*)/){
  9.     print NEWFILE "${1}right$2\n";
  10.     }
  11.     elsif (/(.*)/){
  12.         print NEWFILE "$1\n";
  13.     }
  14. }
  15.